<%@ page language="java" import="java.util.*" pageEncoding="ISO-8859-1"%>
<%
String path = request.getContextPath();
String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/";
%>

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
  <head>
    <base href="<%=basePath%>">
    
    <title>My JSP 'test.jsp' starting page</title>
    
	<meta http-equiv="pragma" content="no-cache">
	<meta http-equiv="cache-control" content="no-cache">
	<meta http-equiv="expires" content="0">    
	<meta http-equiv="keywords" content="keyword1,keyword2,keyword3">
	<meta http-equiv="description" content="This is my page">
	<!--
	<link rel="stylesheet" type="text/css" href="styles.css">
	-->
	<script type="text/javascript" src="js/jquery.js"></script>
	<script type="text/javascript">
		function eachTest(){
			$.each([3, 4, 5], function(i, n){
				alert("The i is " + i + ", The n is " + n);
				if(i == 1)return false;
			});
		}
		
		function selectTest(){
			alert($("#sel").attr("options").length);
		}
		
		function toggleTest()
		{
			$("#div1").toggle("slow");
		}
		
	</script>
  </head>
  
  <body>
  	<select id="sel">
  		<option value="1">sel1</option>
  		<option value="2">sel2</option>
  	</select>
    <input type="button" value="button" onclick="eachTest()"/>
    <input type="button" value="selectTest" onclick="selectTest()"/>
    <input type="button" value="toggleTest" onclick="toggleTest()"/>
    <br/>
    <div id="div1" style="position: absolute; top: 200px;left: 100px">
  		<ul>
  			<li>div1</li>
  			<li>div2</li>
  			<li>div3</li>
  		</ul>
  	</div>
  </body>
</html>
